package com.hualan.sfzy.service;

import com.hualan.sfzy.model.dto.ArticleDto;
import com.hualan.sfzy.model.entity.Article;
import com.hualan.sfzy.model.vo.ArticleQuery;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface ArticleService extends BaseService<Article> {
    Map<String, Object> findArticlePage(Integer pageNum, Integer pageSize, ArticleQuery query);
    
    /**
     * 查询所有文章信息
     */
    List<ArticleDto> findAll();
//文章回收站中的查询
    Map<String, Object> findArticlePageDelelete(Integer pageNum, Integer pageSize, ArticleQuery query);
    List<ArticleDto> findAllDelete();
    int recover(Integer  id);//回复
    int recoverBatch(Integer[] ids);//批量回复
    int removecompletely(Integer id);//彻底删除
    int removeBatchCompletely(Integer[] ids);//批量彻底删除
    int clearExpiredArticles();//清理过期文章
    ArticleDto findRecycleById(Integer id);//查询回收站中的文章详情
    int incrementReadCount(@Param("id") Integer id, @Param("count") Integer count);

}
